package net.sureon.biz;

import java.util.Date;
import java.util.List;

import net.sureon.dao.DailyTiming;
import net.sureon.dao.DailyTimingStatistic;

public interface DailyTimingMgr {
	public long insertDailyTiming(DailyTimingBO dailyTiming);

	public void deleteDailyTiming(long companyID, long dailyTimingID);

	public DailyTiming getDailyTimingByID(long companyID, long dailyTimingID);

	/**
	 * 更改考勤
	 * @param dailyTiming
	 * @return
	 */
	public int updateDailyTiming(long companyID, long dailyTimingID, java.util.Date reviewDate, long reviewedBy, String reviewNote, String status) ;
	
	/**
	 * 用户未审核的申请(Pending)
	 */
	public List<DailyTiming> getDailyTimingByUserNotReview(long companyID, long userID, int skipResults, int maxResults);
	/**
	 * 用户审核过的申请（包括审核不通过和审核通过/NotApproved,Approved）
	 */
	public List<DailyTiming> getDailyTimingByUserReview(long companyID, long userID, int skipResults, int maxResults);
	/**
	 * 未审核的下属申请(Pending)
	 */
	
	public List<DailyTiming> getDailyTimingByGroupNotReview(long companyID, List<Long> idsAsList, int skipResults, int maxResults);
	/**
	 * 审核过的下属申请（包括 NotApproved和Approved）
	 */
	
	public List<DailyTiming> getDailyTimingByGroupReview(long companyID, List<Long> idsAsList, int skipResults, int maxResults);
	
	public List<DailyTimingStatistic> getDailyTimingStatisticInfo(long companyID, long userID) ;
	
	public List<DailyTimingStatistic> getDailyTimingStatisticInfoByGroup(long companyID, List<Long> idsAsList);
	
	
	public List<DailyTimingStatistic> getDailyTimingStatisticInfoByGroup(long companyID, List<Long> idsAsList, Date startDate, Date endDate) ;
	
	/**
	 * 根据考勤日期查找该条考勤记录
	 * @param companyID 公司编号
	 * @param userID 用户编号
	 * @param workDate 工作日期
	 * @return
	 */
	public DailyTiming getDailyTimingByWorkDate(long companyID, long userID, java.util.Date workDate) ;
	
	public int editDailyTiming(long companyID, long dailyTimingID, float workTime, float overTime, float vocationTime, float leaveTime, String workSummary, java.util.Date submitDate, String status) ;
}
